package com.youhome.service.service;

import com.youhome.common.exception.CustomException;
import com.youhome.service.model.BUser;
import com.youhome.service.model.HouseFavourite;
import com.youhome.service.model.Principal;

import java.util.List;

/**
 * Created by chen365 on 2018/08/23.
 */
public interface HouseFavouriteService {
    int deleteByPrimaryKey(Long id);

    int insert(HouseFavourite record);

    HouseFavourite selectByPrimaryKey(Long id);

    List<String> selectHouseIdByUserId(Long userId);

    void add(Principal principal,String id) throws CustomException;

    void delete(Principal principal,String id) throws CustomException;

    List<String> selectAllFavouriteHouseId(Principal principal) throws CustomException;

    void saveFavorite(Principal principal,String action, String houseId) throws CustomException;

    void saveFavorite(BUser user, String action, String houseId) throws CustomException;
}
